using System.Collections;
using System.Collections.Generic;
using UnityEngine;

public class CameraMove : MonoBehaviour
{
    // 摄像机看向的目标
    public Transform targetPlayer;
    private Vector3 pos;
    public float h;

    void LateUpdate()
    {
        if (targetPlayer == null)
            return;
        pos = targetPlayer.position;
        pos.y = h;
        transform.position = pos;
    }
}
